<%-- 
    Document   : warringDelete
    Created on : Nov 5, 2009, 11:08:44 AM
    Author     : Administrator
--%>

<%@page contentType="text/html" pageEncoding="UTF-8" import="java.sql.*,DAO.*"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
<%
            int id = Integer.parseInt(request.getParameter("id"));
            Subject sub = new Subject();
%>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <link rel="stylesheet" type="text/css" media="screen" href="css/admin.css">
        <meta http-equiv="Refresh" Content="5; url=viewSubject.jsp">
        <title>JSP Page</title>
    </head>
    <body>
        <div align="center" s>
            <table border="1" width="600" class="sample">
                <tr>
                    <td>
                        <p align="center">&nbsp;</p>
                        <%
                            boolean checkTest = sub.deleteSubject(id);
                            if(checkTest == true)
                            {
                        %>
                        <p align="center" class="Warring">Bạn đã xóa thành công ! Xin hãy đợi chút xíu ..</p>
                        <p align="center"><div align="center"><img src="images/working.gif"></div></p>
                        <p align="center"> <a href="viewSubject.jsp">Click here</a></p>
                        <%
                            } else {
                        %>
                        <p align="center" class="Warring">Xóa không thành công vì đã có Subject con ! Xin hãy đợi chút xíu ..</p>
                        <p align="center"><div align="center"><img src="images/working.gif"></div></p>
                        <p align="center"> <a href="viewSubject.jsp">Click here</a></p>
                        <%
                            }
                        %>
                    </td>
                </tr>
            </table>
        </div>
        <p align="center">&nbsp;</p>

    </body>
</html>

